1. Field of the Invention
The present invention relates to an image processing apparatus that performs edge enhancement to obtain high-resolution images.
2. Description of the Prior Art
Conventionally, when an image for interlaced scanning or an image whose resolution have been converted is reproduced, the image data of pixels close to pixels having no image data are spatially or temporally interpolated to produce image data so that the thus produced image data are given to the pixels having no image data. At this time, the pixels having no image data are given image data having values close to the image data of the pixels spatially adjacent thereto, and therefore the reproduced image appears blurred, with unclear edges. One known way to avoid this is to use a Laplacian process that achieves edge enhancement of an image by adding to the image data of individual pixels their Laplacian values, i.e. their second spatial derivatives.
However, enhancing edges in an image simply by adding Laplacian values ends in enhancing noise components also, and thus tends to degrade the graininess of the processed image. To solve this problem, Japanese Patent Applications Laid-Open Nos. H5-94515 and H9-91419 propose image processing apparatuses that perform edge enhancement with minimal effects of noise components.
According to the Japanese Patent Application Laid-Open No. H5-94515 mentioned above, black-peak calculation is performed whereby a Laplacian value and a black peak are compared to select whichever is smaller, and also white-peak calculation is performed whereby a Laplacian value and a white peak are compared to select whichever is greater. By performing black-peak and white-peak calculation in this way, it is possible to eliminate Laplacian values having small amplitude components, i.e. those resulting from noise components. However, using threshold values like black and white peaks in this way causes edges having values smaller than those threshold values to be excluded from edge enhancement, and thus no edge enhancement is performed for edges having small intensity-gradients, causing them appear blurred.
On the other hand, according to the Japanese Patent Application Laid-Open No. H9-91419 mentioned above, for all pixels of an image, edge data are detected and their frequency of occurrence is evaluated so that thereafter, in accordance with the evaluated frequency of occurrence, the Laplacian values of the individual pixels are given different weights. By performing the Laplacian process with appropriate weights given to Laplacian values in this way, it is possible to prevent the degradation in graininess of the processed image. However, to select appropriate weights, it is necessary to detect edge data and evaluate their frequency of occurrence for all pixels first, which requires much time. Moreover, it is also necessary to determine weights corresponding to different edge data beforehand by experiments or the like, and therefore, when an image having a different pattern from that of the image used in the experiments is processed, there is a risk of unwanted unevenness appearing in the processed image.
An object of the present invention is to provide an image processing apparatus that performs edge enhancement with minimal effects of noise components.
Another object of the present invention is to provide an image processing apparatus that performs edge enhancement in accordance with the intensity gradients of pixels so as to offer images with satisfactory gradation.
To achieve the above objects, according to the present invention, an image processing apparatus is provided with: a difference calculator that calculates, for each detection-target unit including a predetermined number of pixels, the differences between the values of every two adjacent pixels within the detection-target unit; and a pixel value determiner that changes the values of two pixels located at the center of the detection-target unit in such a way as to increase the difference between the values of those two pixels when the difference between the values of those two pixels has the greatest absolute value within the detection-target unit and all the differences between the values of every two adjacent pixels within the detection-target unit have identical signs.
This image processing apparatus may be so configured that the pixel value determiner changes the values of the two pixels located at the center of the detection-target unit in such a way as to increase the difference between the values of those two pixels when the difference between the values of those two pixels has the greatest absolute value within the detection-target unit, and the difference between the absolute value of the difference between the values of the two pixels located at the center and the absolute values of the differences between the values of the other pixels is greater than a threshold value having a predetermined value, and in addition all the differences between the values of every two adjacent pixels within the detection-target unit have identical signs. This makes it possible to produce high-resolution images with minimal effects of noise components.